<template>
	<view class="sh-richtext-box mb10 f " v-if="richText.content">
		<!-- <view class="f-1 f j-c a-c text-bold"  @click="jump(1)">
			<text class="cuIcon-shopfill " style="margin-top: 10rpx; color: #F8D06B; "></text>
			<text class="margin-left-sm">服务商</text>
		</view>
		<view class="f-1 f j-c  a-c  text-bold" @click="jump(2)">
			<text class="cuIcon-goodsnewfill" style="margin-top: 10rpx;  color: #F8D06B;"></text>
			<text class="margin-left-sm">订单</text>
		</view> -->
		<view class="f r">
			<view
				class="f-1 bg-img "
				style="background-image: url(https://sprtcar.oss-cn-chengdu.aliyuncs.com/images/66777.png);height: 130rpx;width: 50vw;border-radius: 10rpx;"
				@tap.stop="jump('/pages/order/sel')"
			></view>
            <!-- @tap.stop="jump('/pages/order/list')" -->
			<view
				class="f1 bg-img "
				style="background-image: url(https://sprtcar.oss-cn-chengdu.aliyuncs.com/images/6677.png);height: 130rpx; width: 50vw;border-radius: 10rpx;"
				@tap.stop="jump('/pages/user/mshpCrd')"
			></view>
		</view>
	</view>
</template>

<script>
export default {
	components: {},
	data() {
		return {
			richText: '',
		};
	},
	computed: {},
	props: {
		detail: {
			type: Object,
			default: null,
		},
	},
	created() {
		this.detail.id && this.getRichText();
	},
	methods: {
		jump(path, query) {
			console.log('path :>> ', path);
			this.$Router.push({
				path: path,
				query: query,
			});
		},

		getRichText() {
			this.$api('richtext', {
				id: this.detail.id,
			}).then(res => {
				this.richText = res.data;
			});
		},
	},
};
</script>

<style lang="scss">
.sh-richtext-box {
	background: #fff;
	//padding: 0 30rpx;
}
</style>
